Skip to content

fix(pilotctl): reject non-all skill ids in disable/enable (PILOT-394)#260

Merged
TeoSlayer merged 1 commit into
mainfrom
openclaw/pilot-394-20260616-120947
Jun 16, 2026
Merged

fix(pilotctl): reject non-all skill ids in disable/enable (PILOT-394)#260
TeoSlayer merged 1 commit into
mainfrom
openclaw/pilot-394-20260616-120947

Conversation

@matthew-pilot

Copy link
Copy Markdown
Collaborator

What failed

pilotctl skills disable and pilotctl skills enable accept <skill-id|all> but ignore the argument — both commands silently run the global Uninstall / re-enable. disable foo and disable all do the same thing.

Why this fix

Since only one shared SKILL.md exists today, the pragmatic answer is to reject any id except all with a clear error. Per-skill enable/disable can be added in a future ticket when the skillinject library supports per-skill state.

Changes

  • cmdSkillsDisable: validate args[0] == "all", print error otherwise
  • cmdSkillsEnable: validate args[0] == "all", print error otherwise
  • Two new tests pinning the fix for non-all rejection

Verification

  • go build ./cmd/pilotctl/ — clean
  • go vet ./cmd/pilotctl/ — clean
  • go test -count=1 ./cmd/pilotctl/ — all pass (9.65s)
  • make build — all 8 binaries build cleanly
  • New tests TestCLISkillsDisable_RejectsNonAll and TestCLISkillsEnable_RejectsNonAll added

Closes PILOT-394

cmdSkillsDisable and cmdSkillsEnable accept <skill-id|all> but ignore
the argument — 'disable foo' and 'disable all' both run the global
Uninstall. Since only one shared SKILL.md exists today, reject any id
except 'all' with a clear error message directing users to use 'all'
(the per-skill surface will be added in a future ticket).

Changes:
- cmdSkillsDisable: validate args[0] == 'all', error otherwise
- cmdSkillsEnable: validate args[0] == 'all', error otherwise
- Two new tests pinning the fix for non-all rejection

Closes PILOT-394
@TeoSlayer TeoSlayer merged commit 251d798 into main Jun 16, 2026
10 checks passed

@TeoSlayer TeoSlayer left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Debt acknowledged, TBD if per-skill is even relevant. Curated main skill feels more useful.

@matthew-pilot matthew-pilot deleted the openclaw/pilot-394-20260616-120947 branch June 16, 2026 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants